'use strict'

const program = require('commander');
const path = require('path')
const chalk = require('chalk')
// console.log(program)

// program
//   .version('1.0.0')
//   .option('-g, --git [type]', 'Add [marble]', 'Angie')
//   .parse(process.argv);

// console.log('process.argv', process.argv)
// console.log('program.args', program.args)

// console.log('you ordered a pizza with');

// if (program.git) console.log(' - git');
// console.log(' - %s git', program.git)

program
.version('1.0.0')
.option('-i --init [name]', 'init a project', 'myfirstproject')
.parse(process.argv)
if (program.init) {
  console.log(program.init)
}
let projectPath = path.resolve(program.init)
let projectName = path.basename(projectPath)
console.log(chalk.blue(projectName))